Method and device for monitoring the function of an output stage having pulse width modulation

ABSTRACT

The present invention relates to a method and a device for monitoring at least one output stage ( 1 ) which is actuated by a microcontroller (μC) using an input signal ( 2 ) having any pulse duty factor. The output signal ( 3 ) from the output stage ( 1 ) is averaged by an electrical circuit ( 4 ) and compared to a setpoint value ( 5 ) which is calculated from the input signal ( 2 ) of the output stage. An error in the output stage ( 1 ) is diagnosed when the averaged value ( 6 ) deviates from the calculated setpoint value ( 5 ).

TECHNICAL AREA

[0001] Output stages having pulse width modulation are widely used inthe actuation of electrical consumers, such as actuators in motorvehicle engines or in industrial facilities. Output stages supply thepower required by the consumers. Errors such as load drop, short circuitto ground, or short circuit to the positive potential, for example, mayarise in the output stages. For this reason there is a need for a simpleand accurate method of detecting the errors.

BACKGROUND INFORMATION

[0002] German Patent Application 40 12 109 A1 relates to a device formonitoring the function of an electrical consumer, its output stage, itsactuation, and the associated connections. Parallel to the output stage,an error detection logic circuit is connected which distinguishesbetween the following possible types of error: short circuit to ground,short circuit to the positive potential, and load drop, using ahardware-based comparison of the input and output potentials and using areference potential.

[0003] German Patent Application 198 51 732 A1 relates to a method and adevice for monitoring at least one current control level for anelectrical consumer. The current control level has at least oneswitching element and one current controller. A current which isspecified by a pulse duty factor flows through the consumer, it beingpossible for the current controller to set the current to a setpointvalue. To monitor the current control levels, the pulse duty factorand/or a variable derived from the pulse duty factor are compared to athreshold value, and an error is detected when there is a deviation fromthis value. The threshold value results from the particularcorresponding variable which is present in at least one of the othercurrent control levels. The ratio of the time in which the switchingelement is closed to the entire duration of actuation is referred to asthe pulse duty factor. However, the ratio of the time in which theswitching element is closed to the time in which the switching elementis open, for example, may also be used.

[0004] Thus far, primarily two possibilities for monitoring the functionof output stages having pulse width modulation (PWM) have been used inthe related art: evaluating the status output from the intelligentoutput stage, or determining the status by feedback from the outputstage output to a digital port. Neither possibility is suited for theactive PWM operation. In the evaluation of the status signal from theintelligent output stage, the instantaneous status is first delivered ona delayed basis, the delay being specific to the output stage andpossibly being greater than 1 ms, for example. During feedback to adigital input, the output signal must be scanned exactly at a specificpoint in time. This is achievable only with high computing power, up tothe system-dependent limitations. When the two cited possibilities formonitoring the function of PWM output stages are used, it is possible toscan the output signal at the correct time only when the operating timefrom actuation of an output stage to the effect of the control signal atthe output stage output is known.

DESCRIPTION OF THE INVENTION

[0005] The main advantages achievable by the approach according to thepresent invention are that the monitoring of an output stage requiresless computing power, such as for example the synchronous scanningduring digital feedback of the output stage output. In addition, it ispossible to monitor at any time, even when the output stage is in activeoperation. Furthermore, the electrical components necessary formonitoring are economical, standard components such as resistors andcapacitors, for example. An additional advantage of the presentinvention is that the above-mentioned operating times during actuationare equalized by averaging.

[0006] The method according to the present invention and the deviceaccording to the present invention for monitoring output stages aresuited for output stages which are actuated by a microcontroller using asignal having any pulse duty factor, preferably for output stages havingpulse width modulation (PWM). Using the present invention, diagnosis ispossible for PWM high side output stages as well as for PWM low sideoutput stages, independent of the frequency at which they are actuated.The actuation frequency is limited only by the switching times of theoutput stages.

[0007] In the present invention, the output signal from the output stageis averaged by an electrical circuit and compared to a setpoint valuewhich is calculated from the input signal of the output stage. In theaveraging of the output signal it is advantageous that the operatingtime from the actuation of the output stage to the effect of theactuating signal is equalized, and that the output stage may bediagnosed at any time. An error is diagnosed when the averaged valuedeviates from the calculated setpoint value. During trouble-freeoperation, both values (within a tolerance range) are equal. Oneadvantage of the method, in which the two values to be compared resultfrom the input signal and the output signal from one output stage, isthat no additional output stage need be used for comparative values, sothat the diagnosis is performed completely independently from otheroutput stages.

[0008] The output signal from the output stage to be monitored isaveraged in the present invention by using an electrical circuit whichhas at least one resistor and at least one filter, preferably a resistornetwork and one filter. The filter is preferably a low-pass filter whichparticularly preferably contains a capacitor. The advantage of thesepassive components (resistors and capacitors, for example) is that theyare economical due to being standard components. The capacitance of thecapacitors is preferably selected in such a way that the output signalfrom the output stage is smoothed out at a given switching frequency ofthe monitored output stage. The resistors in the resistor network arepreferably dimensioned so that in no-load operation of the output stagea voltage value that is ¼ to ¾ of the battery voltage, preferably ½ ofthe battery voltage, results at the output of the output stage, and theentire operating range of the output stage is represented at the analoginput of the microcontroller.

[0009] In one embodiment of the present invention, the value which isaveraged by the electrical circuit is fed back to an analog input of themicrocontroller, resulting in a specific voltage which depends on thepulse duty factor. The advantage of feedback to an analog input ascompared to a digital input is that the output signal need not bescanned at a precise point in time, thus saving computing power. Tocalculate a setpoint value for comparing to this voltage, themicrocontroller actuating signal is averaged by a software simulation ofthe feedback according to the present invention. In other words,software simulates the output stage and the electrical circuit, andcalculates the circuit output signal which is expected for the outputstage input signal having any pulse duty factor. When an error occurs,it is possible to deduce the type of error, based on the amount by whichthe value averaged by the circuit deviates from the calculated setpointvalue.

DRAWING

[0010] The present invention is explained in greater detail withreference to the drawing.

[0011]FIG. 1 shows the design of a device for monitoring an outputstage.

VARIANTS OF EMBODIMENTS

[0012]FIG. 1 shows one possible embodiment of the device according tothe present invention for monitoring a PWM high side output stage whichmay be used in the method according to the present invention.

[0013] PWM high side output stage 1 having any pulse duty factor isactuated by microcontroller μC. For diagnosing output stage 1, outputsignal 3 from the output stage is fed back to an analog input 8 ofmicrocontroller μC via a resistor network R and a filter 7.

[0014] Resistors R in circuit 4 are dimensioned in such a way, forexample, that in no-load operation a voltage results at output 3 ofoutput stage 1 that is ½ that of battery voltage UB.

[0015] In the embodiment of the present invention illustrated in FIG. 1,a low-pass filter containing a capacitor C is used as filter 7. Thecapacitance of capacitor C is selected in such a way that output signal3 from output stage 1 is smoothed out at the switching frequency presentat the output stage.

[0016] Depending on the pulse duty factor, a voltage at analog input 8of microcontroller μC is present as output signal 6 from circuit 4. Thisvoltage 6 is compared to a setpoint value 5. Setpoint value 5 iscalculated by software simulation of the feedback in microcontroller μC.Output stage 1 and circuit 4 are simulated for averaging output signal 3from output stage 1, and circuit output signal 6 which is expected foroutput stage input signal 2 is calculated. Calculated setpoint value 5is compared to output signal 6 which is averaged by circuit 4. If thetwo values are equal (within a tolerance range), output stage 1 isoperating properly. When an error occurs, averaged value 6 deviates fromsetpoint value 5. Based on the magnitude of this deviation, it ispossible to deduce the type of error.

[0017] If measured value 6 is less than calculated 5, a short circuit toground is diagnosed. If value 6 is greater than calculated 5, either aload drop or a short circuit to battery voltage UB is present. These twoerrors may be distinguished after switching off the output stage. Thevoltage which is then read back corresponds (in this embodiment) to ½that of battery voltage UB during a load drop. If the voltage read backis much greater than this value, the error that occurred is a shortcircuit to battery voltage UB. It is particularly preferred that theresistors are dimensioned so that, as in this example, in no-loadoperation at the output of the output stage is ½ that of battery voltageUB, since this no-load voltage is particularly far removed from the twolimits of 0V at ground and battery voltage UB. It is thus possible todetermine the above-mentioned errors in the simplest manner, since themeasured voltages are limited by tolerances which, due to this greatestpossible difference from the limits, do not overlap with other tolerancebands. The particular defect may thus be accurately detected.

[0018] List of Reference Numbers

[0019]1 Output stage

[0020]2 Input signal of output stage having any pulse duty factor

[0021]3 Output signal from output stage

[0022]4 Circuit for averaging

[0023]5 Calculated setpoint value

[0024]6 Averaged value (output signal from circuit)

[0025]7 Filter

[0026]8 Analog input of microcontroller

[0027] C capacitor

[0028] μC microcontroller

[0029] R resistor

[0030] UB battery voltage

What is claimed is:
 1. A method for monitoring at least one output stage(1) which is actuated by a microcontroller (μC) using an input signal(2) having any pulse duty factor, wherein the output signal (3) from theoutput stage (1) is averaged by an electrical circuit (4) and comparedto a setpoint value (5) which is calculated from the input signal (2) ofthe output stage (1), a deviation of the averaged value (6) from thesetpoint value (5) indicating an error.
 2. The method as recited inclaim 1, wherein the value (6) averaged by the circuit (4) is fed backto an analog input (8) of the microcontroller (μC).
 3. The method asrecited in claim 1, wherein the averaging by the electrical circuit (4)is carried out using at least one resistor (R) and at least one filter(7).
 4. The method as recited in claim 1, wherein the setpoint value (5)is calculated using software.
 5. The method as recited in claim 4,wherein the software simulates the output stage (1) and the electricalcircuit (4), and calculates the output signal (6) from the circuit whichis expected for an input signal (2) of the output stage having any pulseduty factor.
 6. The method as recited in claim 1, wherein it is possibleto deduce the type of error, based on the deviation of the value (6),averaged by the circuit (4), from the setpoint value (5).
 7. A devicefor monitoring at least one output stage (1) which is actuated by amicrocontroller (μC) using an input signal (2) having any pulse dutyfactor, wherein an electrical circuit (4) averages the output signal (3)from the output stage (1), and software calculates from the input signal(2) of the output stage having any pulse duty factor a setpoint value(5) which is compared to the output signal (6) from the circuit (, adeviation of the averaged value (6) from the setpoint value (5)indicating an error.
 8. The device as recited in claim 7, wherein theelectrical circuit (4) has passive components.
 9. The device as recitedin claim 7, wherein the electrical circuit (4) has at least one resistor(R) and at least one filter (7).
 10. The device as recited in claim 9,wherein the filters (7) are low-pass filters.
 11. The device as recitedin claim 10, wherein the low-pass filters contain capacitors (C), thecapacitance of the capacitors (C) being selected in such a way that theoutput signal (3) from the output stage is smoothed out at the switchingfrequency of the monitored output stage (1).
 12. The device as recitedin claim 7, wherein the value (6) averaged by the electrical circuit (4)is fed back to an analog input (8) of the microcontroller (μC).
 13. Thedevice as recited in claim 9 and 12, wherein the resistors (R) in thecircuit (4) are dimensioned so that in no-load operation, a voltagevalue results at the output (3) of the output stage (1) whichcorresponds to ¼ of the battery voltage (UB) to ¾ of the battery voltage(UB).
 14. The device as recited in claim 13, wherein in no-loadoperation, a voltage value results at the output (3) of the output stage(1) which corresponds to ½ of the battery voltage (UB).
 15. The deviceas recited in claim 7, wherein the software simulates the output stage(1) and the electrical circuit (4), and calculates the output signal (6)from the circuit which is expected for an input signal (2) of the outputstage having any pulse duty factor.
 16. The device as recited in claim7, wherein the monitored output stages (1) are high side or low sideoutput stages.